/*
 * Copyright (c) 2022 Kirky
 * Licensed under the Open Software Licence, Version 3.0 (the "License");
 * you may not use this file except in compliance with the License.
 * You may obtain a copy of the License at
 *
 *     https://opensource.org/licenses/osl-3.0.php
 *
 * Unless required by applicable law or agreed to in writing, software
 * distributed under the License is distributed on an "AS IS" BASIS,
 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
 * See the License for the specific language governing permissions and
 * limitations under the License.
 */
package com.bei.lingluan.utils;


import com.bei.lingluan.ResourceTable;

/**
 * @author Kirky
 * @version 1.0
 * @description Describe the permissions and request code required by this application
 * @date 2022/2/10
 */
public enum Permissions {

    CAMERA("CAMERA", "ohos.permission.CAMERA", ResourceTable.String_camera_reason, 101),
    MICROPHONE("MICROPHONE", "ohos.permission.MICROPHONE", ResourceTable.String_microphone_reason, 102),
    INTERNET("INTERNET","ohos.permission.INTERNET",ResourceTable.String_internet_reason,103);

    private final String perName;
    private final String perStr;
    private final int reason;
    private final int resCode;

    Permissions(String perName, String perStr, int reason, int resCode) {
        this.perName = perName;
        this.perStr = perStr;
        this.reason = reason;
        this.resCode = resCode;
    }

    public String getPerName() {
        return perName;
    }

    public String[] getPerStrs() {
        return new String[]{perStr};
    }

    public String getPerStr() {
        return perStr;
    }

    public int getReason() {
        return reason;
    }

    public int getResCode() {
        return resCode;
    }
}
